<?php

class Mail
{
	public static $Mode = 'print';
	public static function Send( $to, $subject, $message, $headers = '', $parameters = '')
	{
		$headers  = 'MIME-Version: 1.0' . "\r\n";
		$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
		
		// Additional headers
		$headers .= 'To: ' . $to ."\r\n";
		$headers .= 'From: Socio Rating <info@sociorating.com>' . "\r\n";
		$headers .=	'Reply-To: info@sociorating.com' . "\r\n";
		
		switch(self::$Mode)
		{
			case 'print':
				?>
				To: <?php print $to ?><br />
				Subject: <?php print $subject ?><br />
				Message: <?php print $message ?><br />
				Additional Headers: <?php print $headers ?><br />
				Additional Parameters: <?php print $parameters ?><br />
				<?php 
				break;
			case 'mail':
				mail($to, $subject, $message, $headers, $parameters);
				break;
		}
	}
}